//配置文件
define('config', function(){
	//var host = 'http://120.26.192.176/msq';
	var host = 'http://localhost/msq';

	return {
		cookieTime: 30*24*60*60*1000,	//cookie失效时间
		api: {
			reg: [host + '/api/user', 'POST'],
			login: [host + '/api/user/login', 'POST'],
			updateInfo: [host + '/api/user/<user_id>', 'PUT'],
			changePass: [host + '/api/user/<user_id>/password', 'PUT'],
			clickZan: [host + '/api/problem/<problem_id>/zan', 'PUT'],
			getComments: [host + '/api/problem/<problem_id>/comments', 'GET'],
			getProblemList: [host + '/api/problems', 'GET'],
			getProblemById: [host + '/api/problem/<problem_id>', 'GET'],
			postComment: [host + '/api/user/<user_id>/comment', 'POST'],
			replyAnswer: [host + '/api/answer/<answer_id>', 'PUT'],
			postAnswer: [host + '/api/user/<user_id>/answer', 'POST'],

			getArticles: [host + '/api/articles', 'GET'],
			getArticleById: [host + '/api/article/<article_id>', 'GET'],
			followStudio: [host + '/api/user/<user_id>/studio', 'PUT'],
			deleteStudio: [host + '/api/user/<user_id>/studio', 'DELETE'],


			getAllProblemOfUser:[host + '/api/user/<user_id>/problems','GET'],
			getAllCommentsOfUser:[host+'/api/user/<user_id>/comments','GET'],
			getUserInfo:[host + '/api/user/<user_id>','GET'],
			getStudioInfo:[host + '/api/studio/<studio_id>','GET'],
			getStudioAnswers:[host+'/api/studio/<studio_id>/answer','GET'],
			getStudioWorks:[host + '/api/studio/<studio_id>/work','GET'],
			getStudioVideos:[host + '/api/studio/<studio_id>/video','GET'],
			getStudioRecruit:[host + '/api/studio/<studio_id>/recruitment','GET'],
			getStudioTeachers:[host + '/api/studio/<studio_id>/teacher','GET'],
			getStudioFans:[host+'/api/studio/<studio_id>/fan','GET'],
			getStudioFollow:[host+'/api/studio/<studio_id>/follow','GET'],
			getOneVideo:[host + '/api/video/<video_id>','GET'],
			subscribeStudio:[host + '/api/user/<user_id>/studio','PUT'],
			cancelSubscribeStudio:[host + '/api/user/<user_id>/studio','DELETE'],
			getAllStudios:[host+'/api/studios','GET'],
			getFollows:[host+'/api/user/<user_id>/follow','GET'],
			followUser:[host+'/api/user/<from_user_id>/follow','POST'],
			getFans:[host+'/api/user/<user_id>/fan','GET'],
			getAllWorks:[host+'/api/user/<user_id>/work','GET'],
			addWorks:[host+'/api/user/<user_id>/work','PUT'],
			deleteWork:[host+'/api/user/<user_id>/work','DELETE'],
			unfollowStudio:[host+'/api/user/<user_id>/studio','DELETE'],
			getAllClassification:[host+'/api/classification/index','GET'],
			getRelationBetweenUser:[host+'/api/user/<user_id1>/relation/<user_id2>','GET'],
			getAnswersOfProblem:[host+'/api/problem/<problem_id>/answers','GET'],
			getCommentsAboutStudio:[host+'/api/studio/<studio_id>/studio-comment','GET'],
			getStudioEnvironment:[host+'/api/studio/<studio_id>/environment','GET'],
			commentStudio:[host+'/api/user/<user_id>/studio-comment','POST']

		}
	};
});
